package com.ruicar.afs.cloud.afscase.addressregion.controller;

import com.ruicar.afs.cloud.common.core.util.IResponse;
import com.ruicar.afs.cloud.parameter.commom.controller.AddressParamController;
import com.ruicar.afs.cloud.parameter.commom.entity.TsysAddressParam;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Description:地址区域控制层
 * @Author:rongji.zhang
 * @Date:2020/8/21 17:52
 * @Version: V1.0
 **/
@Slf4j
@RestController
@AllArgsConstructor
@RequestMapping("/addressRegion")
@Api("地区信息管理")
public class AddressRegionController {

    private AddressParamController addressParamController;

    /**
     * 获取城市树
     *
     * @param
     * @return
     */
    @PostMapping(value = "/getAddressTree")
    @ApiOperation(value = "查询所有合作商首单抵押信息")
    public IResponse<List<TsysAddressParam>> getAddressTree() {
        return addressParamController.getAddressTree();
    }

}
